﻿<%@ Control Language="C#" Inherits="System.Web.Mvc.ViewUserControl" %>
<script type="text/javascript">
    $(document).ready(function () {
        $('#cimg').cycle({
            fx: 'scrollLeft',
            pause: 1,
            delay: 4000
        })
    });
</script>
<table id="banner" border="0" cellpadding="0" cellspacing="0">
    <tr valign="top">
        <td valign="top">
            <div>
                <table cellspacing="0" cellpadding="0" border="0">
                    <tbody>
                        <tr>
                            <td valign="top">
                                <div class="banner">
                                    <div class="cimg" id="cimg">
                                        <% List<Advertising> listBanner = (List<Advertising>)ViewData["ListBigBanner"];
                                           if (listBanner.Count > 0)
                                           {
                                               foreach (Advertising item in listBanner)
                                               {%>
                                        <div style="width: 600px; height: 210px;display:none">
                                            <%string link = string.Empty;
                                              if (item.IsIntenalLink)
                                              {
                                                  link = "<a href='" + FRouter._("quangcao", item.ID.ToString(), item.Title) + "' >";
                                              }
                                              else
                                              {
                                                  link = "<a href='" + item.ExternalLink + "' target='_blank' >";
                                              }
                                              link += "<img  width='600' height='210'  src='" + Constants.UPLOAD_ADV_IMAGE_PATH + item.Image + "' title='" + item.Title + "' /></a>";

                                              Response.Write(link);%>
                                        </div>
                                        <%}
                                           }%>
                                    </div>
                                </div>
                            </td>
                        </tr>
                    </tbody>
                </table>
            </div>
        </td>
    </tr>
    <tr>
    </tr>
</table>
